package com.base.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.base.mapper.voipmapper.NoticesMapper;
import com.base.po.voip.Notices;
import com.base.service.NoticesService;
import com.base.utils.Page;
import org.springframework.transaction.annotation.Transactional;

@Service("noticesService")
public class NoticesServiceImpl implements NoticesService {

	@Autowired
	private NoticesMapper noticesMapper;

	@Override
	@Transactional
	public int deleteByPrimaryKey(String id) {
		return noticesMapper.deleteByPrimaryKey(id);
	}

	@Override
	@Transactional
	public int insert(Notices record) {
		return noticesMapper.insert(record);
	}

	@Override
	@Transactional
	public int insertSelective(Notices record) {
		return noticesMapper.insertSelective(record);
	}

	@Override
	public Notices selectByPrimaryKey(String id) {
		return noticesMapper.selectByPrimaryKey(id);
	}

	@Override
	public int updateByPrimaryKeySelective(Notices record) {
		return noticesMapper.updateByPrimaryKeySelective(record);
	}

	@Override
	public int updateByPrimaryKey(Notices record) {
		return noticesMapper.updateByPrimaryKey(record);
	}

	@Override
	public int countByAll(String userid, Integer type, String createtime) {
		return noticesMapper.countByAll(userid, type, createtime);
	}

	@Override
	public List<Notices> selectByAll(Page page, String userid, Integer type, String createtime) {
		return noticesMapper.selectByAll(page, userid, type, createtime);
	}

	@Override
	public List<Notices> selectByParentId(String parenid) {
		return noticesMapper.selectByParentId(parenid);
	}
}
